{
 "cells": [
  {
   "metadata": {},
   "cell_type": "markdown",
   "source": [
    "RNN可以用来进行文本生成，那么可以用来进行文本分类吗？\n",
    "\n",
    "如果可以，该如何实现？"
   ],
   "id": "af49c590064e231"
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "initial_id",
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "# 示例数据集\n",
    "texts = [\n",
    "    \"I love this movie\",\n",
    "    \"This is a great film\",\n",
    "    \"The plot was terrible\",\n",
    "    \"An amazing performance by the actors\",\n",
    "    \"I dislike this boring story\",\n",
    "    \"The cinematography is stunning\"\n",
    "]\n",
    "\n",
    "labels = [1, 1, 0, 1, 0, 1]  # 1:正面, 0:负面"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 2
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython2",
   "version": "2.7.6"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
